package com.imti.retrofitweatherdemo.logic;

import java.util.List;

public class WeatherResult
{

    private String reason;

    private String error_code;

    private CityWeather result;

    public String getReason()
    {
        return reason;
    }
    public void setReason(String reason)
    {
        this.reason = reason;
    }
    public String getError_code()
    {
        return error_code;
    }
    public void setError_code(String error_code)
    {
        this.error_code = error_code;
    }
    public CityWeather getResult()
    {
        return result;
    }
    public void setResult(CityWeather result)
    {
        this.result = result;
    }
    public class CityWeather
    {

        private String city;

        private CityRealTime realtime;

        private List<WeatherFuture> future;

        public String getCity()
        {
            return city;
        }
        public void setCity(String city)
        {
            this.city = city;
        }
        public CityRealTime getRealtime()
        {
            return realtime;
        }
        public void setRealtime(CityRealTime realtime)
        {
            this.realtime = realtime;
        }
        public List<WeatherFuture> getFuture()
        {
            return future;
        }
        public void setFuture(
            List<WeatherFuture> future)
        {
            this.future = future;
        }
    }

    //"realtime": {
    //            "temperature": "4",
    //            "humidity": "82",
    //            "info": "阴",
    //            "wid": "02",
    //            "direct": "西北风",
    //            "power": "3级",
    //            "aqi": "80"
    //        }
    class CityRealTime
    {

        private String temperature;

        private String humidity;

        private String info;

        private String wid;

        private String direct;

        private String power;

        private String api;

        public String getTemperature()
        {
            return temperature;
        }
        public void setTemperature(String temperature)
        {
            this.temperature = temperature;
        }
        public String getHumidity()
        {
            return humidity;
        }
        public void setHumidity(String humidity)
        {
            this.humidity = humidity;
        }
        public String getInfo()
        {
            return info;
        }
        public void setInfo(String info)
        {
            this.info = info;
        }
        public String getWid()
        {
            return wid;
        }
        public void setWid(String wid)
        {
            this.wid = wid;
        }
        public String getDirect()
        {
            return direct;
        }
        public void setDirect(String direct)
        {
            this.direct = direct;
        }
        public String getPower()
        {
            return power;
        }
        public void setPower(String power)
        {
            this.power = power;
        }
        public String getApi()
        {
            return api;
        }
        public void setApi(String api)
        {
            this.api = api;
        }
    }

    //{
    //                "date": "2019-02-22",
    //                "temperature": "1/7℃",
    //                "weather": "小雨转多云",
    //                "wid": {
    //                    "day": "07",
    //                    "night": "01"
    //                },
    //                "direct": "北风转西北风"
    //            }
    class WeatherFuture
    {

        private String date;

        private String temperature;

        private String weather;

        private WeatherWid wid;

        private String direct;

        public String getDate()
        {
            return date;
        }
        public void setDate(String date)
        {
            this.date = date;
        }
        public String getTemperature()
        {
            return temperature;
        }
        public void setTemperature(String temperature)
        {
            this.temperature = temperature;
        }
        public String getWeather()
        {
            return weather;
        }
        public void setWeather(String weather)
        {
            this.weather = weather;
        }
        public WeatherWid getWid()
        {
            return wid;
        }
        public void setWid(WeatherWid wid)
        {
            this.wid = wid;
        }
        public String getDirect()
        {
            return direct;
        }
        public void setDirect(String direct)
        {
            this.direct = direct;
        }
    }

    class WeatherWid
    {

        private String day;

        private String night;

        public String getDay()
        {
            return day;
        }
        public void setDay(String day)
        {
            this.day = day;
        }
        public String getNight()
        {
            return night;
        }
        public void setNight(String night)
        {
            this.night = night;
        }
    }
}
